home *** CD-ROM | disk | FTP | other *** search
- global gTruckObject, gSimObject, gActorList
-
- on exitFrame
- if the status of gTruckObject = #animating then
- do(the animationScript of gTruckObject)
- go(the frame)
- else
- if the playBack of gTruckObject then
- driveBack(gTruckObject)
- go(the frame)
- else
- if the demoFlag of gSimObject <> 1 then
- updateActors()
- go(the frame)
- else
- if count(gActorList) = 0 then
- createGlobalButtons(gSimObject)
- end if
- if the finishedFlag of gSimObject <> 1 then
- set spriteCell to the cell of gTruckObject
- set index to getPos(the pathList of gSimObject, spriteCell) + 1
- set newMove to getPropAt(the pathList of gSimObject, index)
- set the newMove of gTruckObject to newMove
- moveTruck(gTruckObject, newMove)
- go(the frame)
- else
- afterPlayback()
- end if
- end if
- end if
- end if
- end
-